﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using FluentNHibernate.Mapping;

namespace Coleotrack.Data.Maps
{
    public class ProjectMap : ClassMap<Project>
    {
        public ProjectMap()
        {
            Id(x => x.Id).GeneratedBy.Identity();
            Map(x => x.Abbreviation).Not.Nullable().Unique().Length(5);
            Map(x => x.Name).Not.Nullable().Unique().Length(255);
            Map(x => x.Description).Length(2048);
            References(x => x.ContactPerson);
        }
    }
}
